<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>浮动布局</title>
    <style>
        header{
            height:50px ;
            background: red;
            min-width: 1000px;
        }
        section{
            background: yellow;
            /* overflow:hidden  撑开父元素 */
            overflow: hidden;
            width: 80%;
            margin: 0 auto;
            /* 设置最小宽度    当屏幕宽度小于800时，出现滚动条*/
            min-width: 800px;
        }
        article{
            float: left;
            height: 500px;
            background: gold;
            width: 300px;
            
        }
        slider{
            height: 300px;
            background: green;
            margin-left: 310px;
            display: block;
        }
        footer{
            height: 40px;
            background: pink;
            min-width: 1000px;
        }
    </style>
</head>
<body>
    <header></header>
    <section>
        <article></article>
        <slider></slider>
    </section>
    <footer></footer>
</body>
</html>